package cz.uvn.orthopedy.client;

import java.util.Date;

import com.google.gwt.user.client.rpc.AsyncCallback;

import cz.uvn.orthopedy.client.entity.Doctor;
import cz.uvn.orthopedy.client.entity.Hall;
import cz.uvn.orthopedy.client.entity.Insurance;
import cz.uvn.orthopedy.client.entity.JournalEntry;
import cz.uvn.orthopedy.client.entity.Patient;
import cz.uvn.orthopedy.client.entity.ScheduleEntry;

public interface JournalServiceAsync {

	void initSchedule(ScheduleEntry[] entries, AsyncCallback<Void> callback);
	void getScheduleEntries(AsyncCallback<ScheduleEntry[]> callback);
	void getSchedule(int day, AsyncCallback<ScheduleEntry[]> callback);
	void createScheduleEntry(ScheduleEntry entry, AsyncCallback<Void> callback);
	void editScheduleEntry(ScheduleEntry entry, AsyncCallback<Void> callback);
	void deleteScheduleEntry(ScheduleEntry entry, AsyncCallback<Void> callback);

	void getEntries(Date date, AsyncCallback<JournalEntry[]> callback);
	void createEntry(JournalEntry entry, AsyncCallback<Void> callback);
	void editEntry(JournalEntry entry, AsyncCallback<Void> callback);
	void deleteEntry(JournalEntry entry, AsyncCallback<Void> callback);

	void getHalls(AsyncCallback<Hall[]> callback);
	void createHall(Hall hall, AsyncCallback<Void> callback);
	void editHall(Hall hall, AsyncCallback<Void> callback);
	void deleteHall(Hall hall, AsyncCallback<Void> callback);

	void getInsurances(AsyncCallback<Insurance[]> callback);
	void createInsurance(Insurance insurance, AsyncCallback<Void> callback);
	void editInsurance(Insurance insurance, AsyncCallback<Void> callback);
	void deleteInsurance(Insurance insurance, AsyncCallback<Void> callback);

	void getDoctors(AsyncCallback<Doctor[]> callback);
	void createDoctor(Doctor doctor, AsyncCallback<Void> callback);
	void editDoctor(Doctor doctor, AsyncCallback<Void> callback);
	void deleteDoctor(Doctor doctor, AsyncCallback<Void> callback);

	void getPatients(AsyncCallback<Patient[]> callback);
	void createPatient(Patient patient, AsyncCallback<Long> callback);
	void editPatient(Patient patient, AsyncCallback<Void> callback);
	void deletePatient(Patient patient, AsyncCallback<Void> callback);

}
